﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;

namespace ConsoleApp1
{
    class Computer:Player
        //电脑
    {
        public string name { get; set; }
        static Random rand = new Random();
        public override int getInputWhat()
        {
            int value = rand.Next(1, 4);
            if (value == 1)
            {
                Console.WriteLine("剪刀");
            }
            else if (value == 2)
            {
                Console.WriteLine("石头");
            }
            else if (value == 3)
            {
                Console.WriteLine("布");
            }
            return value;
        }

        public string getPlayerName(int num)
        {
            if (num == 1)
            {
                name = "佛耶戈";
            }
            else if (num == 2)
            {
                name = "大头";
            }
            else if (num == 3)
            {
                name = "莫德凯撒";
            }
            return name;
        }
        //public string fist
        //{
        //    get;
        //    set;
        //}
        //public int cpuShowFist()
        //{
        //    Random r = new Random();
        //    int cnum = r.Next(1, 4);
        //    switch (cnum)
        //    {
        //        case 1: this.fist = "剪刀"; break;
        //        case 2: this.fist = "石头"; break;
        //        case 3: this.fist = "布"; break;
        //    }
        //    return cnum;
        //}
    }
}
